package com.geek.demo01.config;

import com.geek.demo01.model.MyDatasource;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @ClassName JdbcProperties
 * @Description TODO
 * @Author zzm
 * @Data 2020/9/16 19:34
 * @Version 1.0
 */
@Configuration
public class JdbcConfig {

//    @Autowired
//    private JdbcProperties jdbcProperties;

    @Bean
    @ConfigurationProperties(prefix = "geek.datasource")
    public MyDatasource myDataSource() {
        return new MyDatasource();
    }

}
